import fetch from './fetch'
// 万翔
//首页数据  
export const WxHomeList = () => fetch.get('/app/recommend/appIndex')
//banner
export const WxBanner = () => fetch.get('/app/banner')
// 特色课
export const Course = () => fetch.get('/app/courseBasis')
//首页数据
export const lzHomeList = () => fetch.get('/app/recommend/appIndex')
//banner
export const lzBanner = () => fetch.get('/app/banner')

//肖婉
//课程列表
export const xwCourse= (data) =>fetch.get(`/app/courseBasis?page=${data.page}&limit=${data.limit}`)

//课程筛选列表
export const xwCourseChoose= () =>fetch.get(`/app/courseClassify`)

//筛选出来的数据course 
export const xwChooseData= (data) =>fetch.get(`/app/courseBasis?page=${data.page}&limit=${data.limit}&course_type=${data.course_type}&classify_id=${data.classify_id}&order_by=${data.order_by}&attr_val_id=${data.attr_val_id}&is_vip=${data.is_vip}`)

//搜索列表
export const xwSearch = (data) =>fetch.get(`/app/courseBasis?page=${data.page}&limit=${data.limit}&course_type=${data.course_type}&keywords=${data.keywords}`)

//精品课程详情
export const xwDetail = (data) => http.get(`/courseInfo/basis_id=${data}`)

//精品课程详情评论
export const xwDetailPl = (data) => http.post(`/courseComment`, data)

// 删除收藏
export const xwCollect = (data) => http.put(`/collect/cancel/${data}/1`)

// 添加收藏
export const addCollect = (data) => http.post(`/collect`, data)

// 课程详情--立即学习
export const downOrder = (data) => http.post(`/order/downOrder`, data)


//李峥
//获取短信
export const lzGetSMS = (data) => fetch.post('/app/smsCode', data)
//登录
export const lzlogin = (data) => fetch.post('/app/login', data)
//找回密码
export const lzpassword = (data) => fetch.post('/app/password', data)
//省
export const lzcity = () => fetch.get('/app/sonArea/0')
//城
export const lzcitys = (id) => fetch.get('/app/sonArea/' + id)
//区
export const lzcityes = (ids) => fetch.get('/app/sonArea/' + ids)
//个人中心
export const lzuserInfo = () => fetch.get('/app/userInfo')
//更新数据
export const lzupdate = (data) => fetch.put(`/app/user?nickname=${data}`,)
//图片
export const lzimg = (data) => fetch.post(`/app/public/img/`,data)

// 桑俊凯
// 一对一老师列表
export const sjkTeacher = (data) => fetch.get(`/app/otoCourse`, data)
// 一对一老师---老师条件
export const sjkCourseOptions = (data) => fetch.get(`/app/otoCourseOptions`, data)
// 讲师预约
export const sjkReserved = (data) => fetch.get(`/app/teacher/${data}`)

//陈羽嘉
//九宫格
export const cyjjiu = (page,limit,sort) =>fetch.get(`/app/exam/testIndex?page=${page}&limit=${limit}&sort=${sort}`)
//左侧内容
export const cyjleft = () => fetch.get('/app/wap/classify')
//右侧内容
export const cyjright = (id) => fetch.get('/app/wap/quesBank/' + id)
//搜索
export const cyjsou = (data) => fetch.get(`app/wap/search/bank?bank=${data}`)
//套卷分类
export const cyjcart = (id,name) =>fetch.get(`app/exam/packagePractice?page=2&limit=10&done_status=0&classify_id=${id}&name=${name}`)
//移除错题
export  const  cyjwrong = (data) =>fetch.get(`app/myExam/autoDetach/${data}`)

